<!doctype html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<script type="text/javascript" src="http://ajax.microsoft.com/ajax/jquery/jquery-1.4.min.js"></script>
	<script type="text/javascript">
		$(function(){
			$('.top li').click(function() {
				var i = $(this).index();
				$(this).css({'color':'white','background-color':'#80B600'}).siblings().css({'color':'black','background-color':'#F5F5F5'});
				$('.content li').eq(i).css({'color':'white','background-color':'#80B600','display':'block'}).siblings().css({'color':'black','background-color':'#F5F5F5','display':'none'});
			});


		})
	</script>
	<style type="text/css">
		*{
			margin: 0px;
			padding: 0px;
			list-style: none;
		}
		.box{
			width: 400px;
			height: 230px;
			border: 1px solid #EEEEEE;
			margin: 100px auto;
		}
		.top{
			height: 30px;
			width: 100%;
		}
		.top li{
			width: 20%;
			height: 30px;
			float: left;
			line-height: 30px;
			text-align: center;
			background: #F5F5F5 url() 0 0 no-repeat;
			cursor: pointer;
			text-align: center;
		}
		.content{
			width: 400px;
			height: 200px;
			position: relative;
		}
		.content li{
			width: 400px;
			height: 200px;
			position: absolute;
			top: 0px;
			background-color: #80B600 ;
			font-size: 50px;
			line-height: 200px;
			text-align: center;
			color: white;
		}
	</style>
</head>
<body>
	<div class="box">
		<ul class="top">
			<li>tab1</li>
			<li>tab2</li>
			<li>tab3</li>
			<li>tab4</li>
			<li style="color:white;background-color:#80B600;">tab5</li>
		</ul>
		<ul class="content">
			<li>content1</li>
			<li>content2</li>
			<li>content3</li>
			<li>content4</li>
			<li>content5</li>
		</ul>
	</div>
</body>
</html>